import { axios } from '@/utils/request'

const api = {
  list: '/goods/full-minus',
  del: '/goods/full-minus-del',
  details: '/goods/full-minus-edit',
  addOrEdit: '/goods/full-minus-edit',
  deleteAll: '/goods/full-minus-batch'
}

export default api

export function list(parameter) {
  return axios({
    url: api.list,
    method: 'get',
    params: parameter
  })
}

export function del(parameter) {
  return axios({
    url: api.del,
    method: 'get',
    params: parameter
  })
}

export function details(parameter) {
  return axios({
    url: api.details,
    method: 'get',
    params: parameter
  })
}

export function addOrEdit(parameter) {
  return axios({
    url: api.addOrEdit,
    method: 'post',
    data: parameter
  })
}

export function deleteAll(parameter) {
  return axios({
    url: api.deleteAll,
    method: 'post',
    data: parameter
  })
}
